﻿using System;
using System.Data;
using System.Configuration;
using System.Collections;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;

public partial class MasterPage : System.Web.UI.MasterPage
{

    protected void LoginStatus1_LoggedOut(object sender, EventArgs e)
    {
       // base.Session.Abandon();
       // base.Session.Clear();
        base.Response.Redirect("~/Login.aspx");
    }

    protected void Page_Load(object sender, EventArgs e)
    {
        if (!HttpContext.Current.User.Identity.IsAuthenticated)
        {
            base.Response.Redirect(FormsAuthentication.LoginUrl.ToString());
        }
    }
}
